﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;

namespace Web.Controllers
{
    [HandleError]
    public class HomeController : Controller
    {
        public ActionResult Index()
        {
            CheckIfMobileDevice();
            return View();
        }

        private void CheckIfMobileDevice()
        {
            var strUserAgent = Request.UserAgent.ToLower();
            if (Request.Browser.IsMobileDevice == true || strUserAgent.Contains("iphone") ||
                    strUserAgent.Contains("blackberry") || strUserAgent.Contains("mobile") ||
                    strUserAgent.Contains("windows ce") || strUserAgent.Contains("opera mini") ||
                    strUserAgent.Contains("palm"))
            {
                Response.Redirect("http://m.ban-centar.hr");
            }
        }

        public ActionResult o_projektu()
        {
            return View();
        }

        public ActionResult stanovi()
        {
            return View();
        }

        public ActionResult poslovni_prostori()
        {
            return View();
        }

        public ActionResult garaze()
        {
            return View();
        }

        public ActionResult trazilica()
        {
            return View();
        }

        public ActionResult najcesca_pitanja()
        {
            return View();
        }

        public ActionResult kontakt()
        {
            return View();
        }

        public ActionResult etaza_minus1()
        {
            return View();
        }

        public ActionResult prizemlje()
        {
            return View();
        }

        public ActionResult etaza1()
        {
            return View();
        }

        public ActionResult etaza2()
        {
            return View();
        }

        public ActionResult etaza3()
        {
            return View();
        }

        public ActionResult etaza4()
        {
            return View();
        }

        public ActionResult etaza5()
        {
            return View();
        }

        public ActionResult etaza6()
        {
            return View();
        }

        public ActionResult etaza7()
        {
            return View();
        }
    }
}
